package cn.xzhang.boot.model.entity;

import cn.xzhang.boot.common.pojo.BaseDO;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import org.springframework.format.annotation.DateTimeFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;


import java.io.Serializable;

/**
* 壁纸下载记录
* @TableName WallpaperDownloadRecord
* @author <a href="https://github.com/XiaoZhangCode">XiaoZhangCode</a>
*/
@TableName(value ="wallpaper_download_record")
@Data
public class WallpaperDownloadRecord implements Serializable {


    @TableId(type = IdType.ASSIGN_ID)
    @Schema(description = "id")
    private Long id;

    @Schema(description = "壁纸id")
    private Long wallpaperId;

    @Schema(description = "用户id")
    private Long userId;

    @Schema(description = "下载次数",requiredMode = Schema.RequiredMode.REQUIRED)
    private Integer downloadCount;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Schema(description = "最后一次下载时间",requiredMode = Schema.RequiredMode.REQUIRED)
    private java.util.Date lastDownloadTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}